// $Id$
// vim:ft=javascript

ARG_ENABLE("rar", "Rar support", "no");

if (PHP_RAR != "no") {
	EXTENSION("rar", "rar.c rar_error.c rararch.c rarentry.c rar_stream.c rar_navigation.c rar_time.c", PHP_RAR_SHARED, "/DRARDLL /DSILENT /EHsc /D_WSTDIO_DEFINED");
	ADD_SOURCES(configure_module_dirname + "/unrar",
		"sha256.cpp qopen.cpp \
		blake2s.cpp recvol.cpp \
		headers.cpp match.cpp \
		find.cpp \
		resource.cpp \
		pathfn.cpp \
		dll.cpp threadpool.cpp volume.cpp \
		unpack.cpp \
		extract.cpp errhnd.cpp \
		crc.cpp rijndael.cpp crypt.cpp \
		rawread.cpp \
		rs.cpp smallfn.cpp \
		isnt.cpp rar.cpp consio.cpp \
		scantree.cpp archive.cpp strfn.cpp \
		strlist.cpp \
		getbits.cpp hash.cpp \
		filestr.cpp \
		extinfo.cpp ui.cpp rarvm.cpp \
		timefn.cpp sha1.cpp \
		rdwrfn.cpp rs16.cpp cmddata.cpp \
		extractchunk.cpp system.cpp \
		unicode.cpp filcreat.cpp \
		arcread.cpp filefn.cpp \
		global.cpp list.cpp \
		encname.cpp file.cpp \
		secpassword.cpp options.cpp", "rar");

	AC_DEFINE("HAVE_RAR", 1, "Rar support");
}
